home *** CD-ROM | disk | FTP | other *** search
/ PC World 2007 June / PCWorld_2007-06_cd.bin / temacd / wikipad / WikidPad-1.9beta2.exe / {app} / WikidPadHelp / data / SpellChecking.wiki < prev    next >
Encoding:
Text File  |  2006-08-02  |  5.2 KB  |  115 lines

  1. ∩╗┐++ Spell Checking
  2.  
  3. If you have installed the spell check add-on (for Windows binary distribution) or the pyEnchant library (for source distribution) you can run a spell check for a page or the whole wiki.
  4.  
  5. You should be able to retrieve the add-on from the same place where you loaded WikidPad from. The add-on should be installed after WikidPad is installed and in the same directory as WikidPad. When deinstalling WikidPad, the add-on must be deinstalled separately.
  6.  
  7. The enchant library allows to use multiple of the available spell checker programs (like ISpell) and the dictionaries created for them.
  8.  
  9. The standard pyEnchant library (and the add-on package) provides ISpell and MySpell as spell checkers.
  10.  
  11.  
  12. ++ Available dictionaries
  13.  
  14. The add-on already contains MySpell dictionaries for the languages:
  15.  
  16. <<pre
  17. en_US   English (US)
  18. en_GB   English (UK)
  19. de_DE   German (Germany)
  20. fr_FR   French (France)
  21. >>
  22.  
  23. MySpell is also used by OpenOffice, so the dictionaries available at
  24.  
  25. http://lingucomponent.openoffice.org/spell_dic.html
  26.  
  27. should work as well.
  28.  
  29. A dictionary consists of a .dic and an .aff file with the same name (like e.g. "en_US"). To install a new one, go to the installation directory of WikidPad, then in dir. "share" down in dir. "enchant". There you will see directories "ispell" and "myspell". Just copy the .dic and .aff files into the directory for the appropriate spell checker (ispell or myspell). After that WikidPad should be ready to use the dictionary.
  30.  
  31.  
  32.  
  33. ++ Defining the language
  34.  
  35. You must define the language of a page or the whole wiki by specifying the "language" or "global.language" attribute. The language is just the name of the dictionary.
  36.  
  37. To use US-English on this page, write
  38.  
  39. [language: en_US]
  40.  
  41. for the whole wiki write:
  42.  
  43. [global.language: en_US]
  44.  
  45. the page must be saved then to bring the attribute into effect.
  46.  
  47.  
  48.  
  49. ++ What is a word?
  50.  
  51. Spell checking requires at first to find the words in the content. The regular expression used to find words is located in the "WikiSyntax.py" file (in the directory "extensions" or "user_extensions", see [WikiSyntax]) and looks about like:
  52.  
  53. <<pre
  54. TextWordRE = re.compile(ur"(?P<negative>[0-9]+|"+ UrlRE.pattern + u"|" +
  55.         WikiWordRE.pattern + ur")|\b[\w']+",
  56.         re.DOTALL | re.UNICODE | re.MULTILINE)
  57. >>
  58.  
  59.  
  60. If you have some experience with regular expressions, you can change it. 
  61.  
  62. The expression contains a named group "negative". If something matches one of the entries in this group (joined with '|'), this is *not* interpreted as word (by default numbers, URLs and camel-case wiki words). This allows to ignore unwanted patterns.
  63.  
  64.  
  65.  
  66. ++ The spell check dialog
  67.  
  68. To open the spell check dialog, select "Spell check" (below "Set Date Format") in "Editor" menu. If the menu entry isn't there, the installation of the add-on package went wrong.
  69.  
  70. After opening the dialog, it starts at the beginning of the page and searches for spelling errors. If it found one, the error is shown in red with some context before and after it in the "To check" area.
  71.  
  72. You have now the possibility to correct the error in the "Replace with" field or choose a suggestion for the right spelling in the list below the field and then click on "Replace" or hit return to go to the next error.
  73.  
  74. The available buttons have the following meanings:
  75.  
  76. *Ignore*
  77. Ignore this error and find the next one.
  78.  
  79. *Ignore All*
  80. Ignore this error and if a word with exactly the same spelling (including case) is found later again, ignore this too.
  81.  
  82. *Replace*
  83. Replace the error with the text entered in "Replace with".
  84.  
  85. *Replace All*
  86. Replace the error and if a word with exactly the same spelling (including case) is found later again, correct it in the same way.
  87.  
  88. *Add Globally*
  89. Add the found word to the permanent application-wide list of words to ignore.
  90.  
  91. *Add Locally*
  92. Add the found word to the permanent wiki-wide list of words to ignore.
  93.  
  94. *Done*
  95. Close dialog.
  96.  
  97.  
  98. *Checkbox 'Go to next page'*
  99. If the spell checker reaches the end of the current page and this check box is checked, it goes on to the "next" page. "Next" means here the following wiki word in alphabetical order (case sensitive), so the spell checking might jump around in the tree on the left.
  100.  
  101.  
  102. +++ Remarks
  103.     * The lists maintained by "Ignore All" and "Replace all" with the already found words are cleared when closing the dialog.
  104.     
  105.     * The dialog is non-modal, this means you can edit the wiki page while the dialog is open. When pressing "Ignore", the spell checker always starts searching where you left the cursor, so you can go to another page and place the cursor where you want that searching should go on.
  106.     
  107.     * The dialog can't be used to check functional pages like the text blocks pages (see [TextBlocks]).
  108.  
  109.  
  110. +++ The permanent word lists
  111. With the buttons "Add Globally" and "Add Locally" you can add a word to a permanent ignore list. You can edit this lists as functional pages named "Global spell list" and "Wiki spell list" under the "Views" node in tree, in the "Func. pages" section.
  112.  
  113. Each line contains a word to ignore during spell checking. You can add, modify or delete words or the whole list arbitrarily and cut & paste words between the lists.
  114.  
  115.